package com.cqgc.mapper;


import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.cqgc.entity.User;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;
import java.util.Map;

@Mapper
public interface UserMapper extends BaseMapper<User> {
    //批量删除
//    void batchUpdateState(@Param("users") List<User> users);
    User getUserById(int id);
    List<User> getUserByRole(int role);
    User getUserByAccountAndPassword(@Param("account") String account, @Param("password") String password);
    User getRoleByAccount(String account);
    int insertUser(User user);
    User getUserByAccount(@Param("account") String account);

}
